import * as types from '../mutation-types'

// initial state
const state = {
  buttonInfo: {}
}

// getters
const getters = {
  getButtonInfo: state => state.buttonInfo
}

// actions
const actions = {
  setButtonInfo ({commit}, setButton) {
    commit(types.SET_BUTTON_INFO, setButton)
  }
}

// mutations
const mutations = {
  [types.SET_BUTTON_INFO] (state, buttonInfo) {
    state.buttonInfo = buttonInfo
  }
}

export default {
  state,
  getters,
  actions,
  mutations
}
